using System;

namespace CommonPatterns.MVVM
{
    /// <summary>
    /// This attribut is used to link a view to a view model.
    /// BE AWARE!!
    /// this class is used because of the project AvalonDock in order to load a 
    /// persisted view, which needs to be linked to a ViewModel instance
    /// </summary>
    [AttributeUsage(AttributeTargets.Class)]
    public class MappedToWiewModel : Attribute
    {
        public Type ViewModelType { get; private set; }

        public MappedToWiewModel(Type viewModelType)
        {
            ViewModelType = viewModelType;
        }
    }
}